package com.cci.kangdao.task;

import com.cci.kangdao.dao.CRMPlatformServiceDao;
import com.cci.kangdao.redis.RedisClientUtils;
import org.springframework.scheduling.annotation.Async;

import java.util.List;
import java.util.Map;

/**
 * @description: 异步线程，执行程序中非必要同步执行的逻辑
 * @author: shiliqiang
 * @company: CTY Technology Co.,Ltd
 * @since: 2021/11/19 15:22
 * @version: V1.0
 */
public interface AsyncTask {

    @Async
    public void userActionRecord(Map<String, Object> map);

    /**
     * @description: 保存工单负责人
     * @param:
     * @return:
     * @exception:
     * @author: shiliqiang
     * @company: CTY Technology Co.,Ltd
     * @since: 2021/11/19 16:26
     * @version: V1.0
     */
    @Async
    public void saveOrderPrincipal(Map<String, Object> map);

    @Async
    public void newSendMsg(Map<String, Object> map, List<Map<String, Object>> sendList, int phoneMsg, int appMsg, Map<String, Object> otherMsg);

    @Async
    public void asyncOrderStatusToCrm(String channalName, CRMPlatformServiceDao serviceDao, RedisClientUtils redisClientUtils, Map<String, Object> parameters);

    public List<Map<String, Object>> sendMsg(Map<String, Object> map, List<Map<String, Object>> sendList, int phoneMsg, int appMsg, Map<String, Object> otherMsg);

}